<script setup>
import { getcloseCinema } from "../../api/home";
import { onMounted, reactive } from "vue";
import Cinema from "../CloseCinema.vue";
const data = reactive({
  cinemaList: [],
  choseList: [],
});

onMounted(() => {
  getcloseCinema().then((res) => {
    console.log("附近影院列表", res);
    data.cinemaList = res.data;
  });
  // ChosecloseCinema().then(res=>{
  //     console.log("影院筛选条件",res)
  // })
});
</script>
<template >
  <div class="cenima">
    <div class="warp">
      <div class="tab">
        <div class="item city">
          <span>全城</span>
          <span class="drop"></span>
        </div>
        <div class="item brand">
          <span>品牌</span>
          <span class="drop"></span>
        </div>
        <div class="item characteristic">
          <span>特色</span>
          <span class="drop"></span>
        </div>
      </div>
      <div class="kong"></div>
    </div>
    <Cinema :list="data.cinemaList"></Cinema>
  </div>
</template>
<style scoped lang="scss">
* {
  margin: 0;
  padding: 0;
}
.warp {
  width: 100%;
  height: 30px;
  z-index: 10;
  background-color: #fff;
  position: relative;
  .tab {
    display: flex;
    text-align: center;
    width: 100%;
    .item {
      flex: 1;
      text-align: center;
      line-height: 30px;
      position: relative;
      white-space: nowrap;
      overflow: hidden;
      text-overflow: ellipsis;
      span {
        font-size: 12px;
        color: grey;
      }
    }
  }
}
.item + .item:before {
  content: "";
  display: block;
  position: absolute;
  height: 16px;
  top: 8px;
  left: 0;
  border-left: 0.02rem solid #e8e8e8;
}
.drop {
  display: inline-block;
  position: absolute;
  top: 14px;
  width: 0;
  height: 0;
  margin-left: 4px;
  border: 4px solid transparent;
  border-top-color: #b0b0b0;
}
.kong{
  height: 20px;
}
</style>